/*
 * Copyright (c) 2018, apexes.net. All rights reserved.
 *
 *         http://www.apexes.net
 *
 */
package net.apexes.commons.guice.tx;

/**
 * @deprecated 使用 {@link Txn}
 * @author <a href="mailto:hedyn@foxmail.com">HeDYn</a>
 */
@Deprecated
public class Txs {
    private Txs() {
    }

    /**
     * @deprecated 使用 {@link Txn#addAfterTxCommit(Runnable)}
     */
    @Deprecated
    public static void addAfterCommit(Runnable runnable) {
        Txn.addAfterTxCommit(runnable);
    }

    /**
     * @deprecated 使用 {@link Txn#addAfterTxCommit(Runnable)}
     */
    @Deprecated
    public static void addAfterTxCommit(Runnable runnable) {
        Txn.addAfterTxCommit(runnable);
    }

    /**
     * @deprecated 使用 {@link Txn#addAfterTxRollback(Runnable)}
     */
    @Deprecated
    public static void addAfterRollback(Runnable runnable) {
        Txn.addAfterTxRollback(runnable);
    }

    /**
     * @deprecated 使用 {@link Txn#addAfterTxRollback(Runnable)}
     */
    @Deprecated
    public static void addAfterTxRollback(Runnable runnable) {
        Txn.addAfterTxRollback(runnable);
    }

    /**
     * @deprecated 使用 {@link Txn#isWithinTx()}
     */
    @Deprecated
    public static boolean isWithinTx() {
        return Txn.isWithinTx();
    }

}